'use strict';

angular.module('com.dcos.app').factory('DashBoardService', function($http) {
	return {
		getlist: function (project_id) {
	      return $http({
	        method: 'POST',
	        url:'/v1/pipstat/list',
	        data:JSON.stringify({project_id:project_id}),
	        headers: {'Content-type': 'application/json','Accept': 'application/json'}
	      })
	    },
		barReport: function (project_id) {
	      return $http({
	        method: 'POST',
	        url:'/v1/report/bar',
	        data:JSON.stringify({project_id:project_id}),
	        headers: {'Content-type': 'application/json','Accept': 'application/json'}
	      })
	    },
		pieReport: function (project_id) {
	      return $http({
	        method: 'POST',
	        url:'/v1/report/pie',
	        data:JSON.stringify({project_id:project_id}),
	        headers: {'Content-type': 'application/json','Accept': 'application/json'}
	      })
	    }
	}
});
